﻿$(function () {
    $("#send").click(function () {
        $.post("/Server/SendMess", $("#mess").value, GetCallback, "json");
        alert("get!!");
    });
});
function GetMess() {
    setTimeout(GetMess, 3000);
    $.post("/Server/GetMess", null, GetCallback, "json");
}
function GetCallback(data) {
    //alert(data);
    /*$.each(data, function (i) {
        $("#chat").append("<p>" + this. + "</p>");*/
        $("#chat").append("<p>" + data.message + "</p>");
        alert(data);
        //GetMess();
    });


}